package com.zhiyou100.api.io_demo;

import java.io.Serializable;
import java.time.LocalDate;

//图书信息类
public class BookInfo implements Serializable {

    static final long serialVersionUID = 1L;

    private String id; // 编号
    private String name; // 名称
    private int price; // 价格
    private String author; // 作者
    private LocalDate startTime; // 出版时间

    @Override
    public String toString() {
        return "BookInfo{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", price=" + price +
                ", author='" + author + '\'' +
                ", startTime='" + startTime + '\'' +
                '}';
    }

    public BookInfo() {
    }

    public BookInfo(String id, String name, int price, String author, LocalDate startTime) {
        this.id = id;
        this.name = name;
        this.price = price;
        this.author = author;
        this.startTime = startTime;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getPrice() {
        return price;
    }

    public void setPrice(int price) {
        this.price = price;
    }

    public String getAuthor() {
        return author;
    }

    public void setAuthor(String author) {
        this.author = author;
    }

    public LocalDate getStartTime() {
        return startTime;
    }

    public void setStartTime(LocalDate startTime) {
        this.startTime = startTime;
    }
}
